package com.itboye.jigongbao.utils

import org.json.JSONObject

/**
 * Created by Administrator on 2018/1/12.
 */
class ByJsonUtils {
    companion object {
        fun parseJson(jsonStr: String, key: String): Any? {
            var value: Any? = null
            try {
                var jsonObject: JSONObject = JSONObject(jsonStr)
                if (jsonObject.has(key)) {
                    value = jsonObject.get(key)
                }
            } catch (e: Exception) {

            }
            return value
        }
    }
}